<style>
    .xh-area-form label {
        width: 115px;
    }
    /*body {*/
        /*background-color: #f9f9f9;*/
    /*}*/

    .kv-file-content img{
        width: auto;
        height: 150px;
        max-width: 130px;
    }
    .file-footer-caption {
        display: block;
        white-space: nowrap;
        text-overflow: ellipsis;
        width: 120px;
        text-align: center;
        padding-top: 4px;
        font-size: 11px;
        color: rgb(119, 119, 119);
        overflow: hidden;
        margin: 5px auto;
    }
    .xh-form .btn {
        margin-right: 2px;
        padding-left: 10px;
        padding-right: 10px;
    }

</style>
<script>
   var applyInfo = {{ applyInfo| json_encode }};
   var SchoolList = {{ SchoolList }};
   var financeEdit = {{ financeEdit }};
   var ifEdit = {{ ifEdit }};
</script>
<form id="xh_form" class="xh-form" method="post" enctype="multipart/form-data">
    <div class="smart-widget">
        <div class="smart-widget-inner">
            <div class="smart-widget-body">
                <div class="xh-area-form" style="display: flex;">
                    <table style="border-collapse:separate;">
                        <tbody style="display: block">
                        {% if iType != 8 and iType != 9  %}
                        <tr>
                            <td style="margin-left: 200px;"><label style="width: 70px">所属学校</label></td>
                            <td>
                                <select  id="iSchoolId" name="iSchoolId" style="width: 300px;" >
                                </select>
                            </td>
                            {% if iType == 5 %}
                                <td><label style="width: 80px">学校联系人</label></td>
                            {% else %}
                                <td><label style="width: 70px">学生姓名</label></td>
                            {% endif %}
                            <td>
                                <select  id="iStudId" name="iStudId" style="width: 300px;" >
                                </select>
                            </td>
                            <input type="hidden" name="sStudName">
                        </tr>
                        {% endif %}
                        {% if iType == 1 %}
                            <tr>
                                <td><label style="width: 85px;">教师子女类型</label></td>
                                <td>
                                    <select  id="iTypeExpansion" name="iTypeExpansion" style="width: 300px;font-size: 13px;">
                                        <option value="1">请选择</option>
                                        {% for key ,value in typeExpansion[iType] %}
                                            <option value = '{{key}}'>{{value}}</option>
                                        {% endfor %}
                                    </select>
                                </td>
                                <td id="iDev" style="display: none"  colspan="2">
                                    <label style="width: 70px;display: inline-block;">设备费</label>
                                    <input style="width: 100px;display: inline-block;" type="text" name="dDevCost" id="iDevCost" value="">
                                    <label style="width: 70px;display: inline-block;margin-left: 20px;">服务费</label>
                                    <input style="width: 100px;display: inline-block;" type="text" name="dSerCost" id="iSerCost" value="">
                                </td>
                            </tr>
                            <tr>
                                <td><label style="width: 80px">上传教师证</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple" id='tch_img' name="tch_img[]" accept="image/*">
                                </td>
                            </tr>
                            <tr>
                                <td><label style="width: 90px">出生证/户口本</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple" id='relation_img' name="relation_img[]" accept="image/*">
                                </td>
                            </tr>
                        {% elseif iType == 2 %}
                            <tr>
                                <td><label style="width: 80px">贫困生等级</label></td>
                                <td>
                                    <select  id="iTypeExpansion" name="iTypeExpansion" >
                                        <option value=0>请选择</option>
                                        {% for key ,value in typeExpansion[iType] %}
                                            <option value = '{{key}}'>{{value}}</option>
                                        {% endfor %}
                                    </select>
                                </td>
                            </tr>
                            <tr>
                                <td style="position:relative"><label style="width: 115px">家庭低保/贫困证明</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple" id='family_img' name="family_img[]" accept="image/*">
                                </td>
                            </tr>
                            <tr>
                                <td><label style="width: 85px">学校贫困证明</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple" id='stud_img' name="stud_img[]" accept="image/*">
                                </td>
                            </tr>
                            <tr>
                                <td><label style="width: 85px">平板借用协议</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple" id='borrow_img' name="borrow_img[]" accept="image/*">
                                </td>
                            </tr>
                        {% elseif iType == 5 %}
                            <tr>
                                <td><label style="width: 70px;">领导证明</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple" id='leader_img' name="leader_img[]" accept="image/*">
                                </td>
                            </tr>
                        {% elseif iType == 6 or iType == 8 %}
                            <tr>
                                {% if iType == 6 %}
                                    <td><label style="width: 70px;">家长姓名</label></td>
                                    <td><input id="sLeadName" type="text" name="sLeadName"></td>
                                {% else %}
                                    <td><label style="width: 70px;">姓名</label></td>
                                    <td><input id="sStudName" type="text" name="sStudName"></td>
                                {% endif %}
                                <td><label style="width: 70px;">职务</label></td>
                                <td><input id="sLeadPosition" type="text" name="sLeadPosition"></td>
                            </tr>
                            <tr>
                                {% if iType == 8 %}
                                    <td><label style="width: 70px;">单位名称</label></td>
                                    <td><input id="sLeadCompany" type="text" name="sLeadCompany" style="width: 300px;"></td>
                                {% endif %}
                                <td><label style="width: 70px;">联系电话</label></td>
                                <td><input id="sLeadPhone" type="text" name="sLeadPhone" style="width: 300px;"></td>
                            </tr>
                        {% elseif iType == 7 %}
                            <tr>
                                <td><label style="width: 70px;">缴费状态</label></td>
                                <td>
                                    <select  id="iPayState" name="iPayState" >
                                        {% for key ,value in payState %}
                                            <option value = '{{key}}'>{{value}}</option>
                                        {% endfor %}
                                    </select>
                                </td>
                            </tr>
                            <tr>
                                <td><label style="width: 70px;">相关附件</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple" id='grant_img' name="grant_img[]" accept="image/*">
                                </td>
                            </tr>
                        {% endif %}

                        {% if bEstablished == 1 or financeEdit == 1 %}
                            <tr>
                                <td><label style="width: 70px">财务附件</label></td>
                                <td colspan="3" style="width:720px">
                                    <input type='file' multiple="multiple"  id='finance_img' name="finance_img[]" accept="image/*">
                                </td>
                            </tr>
                        {% endif %}
                        {% if iType == 9 %}
                            <tr>
                                <td style="margin-left: 200px;"><label style="width: 70px">所属学校</label></td>
                                <td>
                                    <select  id="iSchoolId" name="iSchoolId" style="width: 300px;" >
                                    </select>
                                </td>
                                <td><label style="width: 70px">学生姓名</label></td>
                                <td><input id="sStudName" type="text" name="sStudName" style="width: 300px;"></td>
                            </tr>
                            <tr>
                                <td style="margin-left: 200px;"><label style="width: 70px">账号</label></td>
                                <td>
                                    <input id="sAccountNum" type="text" name="sAccountNum" style="width: 300px;">
                                </td>
                                <td><label style="width: 70px">身份证号码</label></td>
                                <td><input id="sIdentityNum" type="text" name="sIdentityNum" style="width: 300px;"></td>
                            </tr>
                        {% endif %}
                        <tr>
                            <td valign="middle"><label style="width: 70px">备注</label></td>
                            <td colspan="3">
                                <textarea border="0" name="sRemarks" rows="3"></textarea>
                                <input type="hidden" name="iType" id="iType" value="{{ iType }}">
                                <input type="hidden" name="iId" id="applyId" value="{{ iId }}">
                                <input type="hidden" name="bEstablished" id="bEstablished" value="{{ bEstablished }}">
                            </td>
                        </tr>
                        <tr>
                            <td></td>
                            <td><div class="xh-area-button" style="padding-left: 0px;">
                                    {% if FormButton is defined %}{{ FormButton }}{% endif %}
                                </div>
                            </td>
                        </tr>
                        </tbody>
                    </table>
                </div>

            </div>
        </div>
    </div>


</form>
